function getApiData(api) {
  let apiMap = [
    {url:'/web/page/index/info', data:require('./data/page/index/info')},
    {url:'/web/article/info/list', data:require('./data/article/info/list')},
    {url:RegExp('/web/article/info/' + ".*" + '/detail'), data:require('./data/article/info/detail')}
  ]
  for(let i = 0; i < apiMap.length; i++) {
    if (typeof(apiMap[i].url)=="string") {
      if (apiMap[i].url==api) {
        return apiMap[i].data
      }
    } else {
      if (apiMap[i].url.test(api)) {
        return apiMap[i].data
      }
    }
  }
  return ""
}
export default getApiData
